[release/9.0-staging] Detect if RSA-384 is supported on the platform#120382
Merged
bartonjs merged 1 commit intodotnet:release/9.0-stagingfrom Oct 3, 2025
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull Request Overview
Backport test-only change to dynamically detect RSA-384 key support instead of using OS string heuristics, stabilizing previously failing cryptography tests on updated Windows versions.
- Centralizes RSA-384 capability detection in PlatformSupport.IsRSA384Supported.
- Replaces per-provider ad hoc logic with a shared Lazy-based capability probe.
- Adds embedded 384-bit RSA key parameters for runtime import testing on Windows.
Reviewed Changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| System.Security.Cryptography/tests/DefaultRSAProvider.cs | Replaces cached OSDescription heuristic with PlatformSupport.IsRSA384Supported. |
| System.Security.Cryptography.Csp/tests/RSACryptoServiceProviderProvider.cs | Uses new shared RSA-384 support detection instead of unconditional true. |
| System.Security.Cryptography.Cng/tests/RSACngProvider.cs | Removes duplicated heuristic logic in favor of centralized detection. |
| Common/tests/System/Security/Cryptography/PlatformSupport.cs | Adds RSA-384 parameter set and Lazy-based runtime capability detection exposed via IsRSA384Supported. |
Contributor
|
Tagging subscribers to this area: @dotnet/area-system-security, @bartonjs, @vcsjones |
bartonjs
approved these changes
Oct 3, 2025
Member
|
Test-only change, tell-mode. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Backport of #120366 to release/9.0-staging
/cc @bartonjs
Customer Impact
This is test-only reaction to a change in Windows. Tests started failing in Windows because a Windows Update caused RSA with a 384-bit modulus to fail.
Regression
Testing
This is test only change. Verified failing tests started passing again.
Risk
None. Test-only change.